package com.example.springboot.model;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import io.swagger.v3.oas.annotations.media.Schema;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.NotNull;
import lombok.Data;

@Data
@Schema(description = "保存一级路由参数")
public class SubmenuSaveParam {

    @NotNull(message = "id不能为空")
    @Schema(description = "序号")
    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;

    @NotBlank(message = "名称不能为空")
    @Schema(description = "名称")
    @TableField("label")
    private String label;

    @NotBlank(message = "图标不能为空")
    @Schema(description = "图标")
    @TableField("icon")
    private String icon;

    @NotNull(message = "状态不能为空")
    @Schema(description = "状态")
    @TableField("state")
    private Integer state;

}
